package net.hombrecero.bigbeat.model;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

import org.hibernate.annotations.AccessType;

@Entity
@AccessType( "field" )
public class App extends Base {
	public static final int APPSTATUS_DISABLED = 1;
	public static final int APPSTATUS_ENABLED  = 2;

    @ManyToOne( cascade = { CascadeType.PERSIST, CascadeType.MERGE } )
    @JoinColumn( name="uuidProject", nullable=false )
    private Project project;
	@Column( length=32, nullable = false )
	private String name;
	@Column( length=16, nullable = false )
	private String alias;
	@Column( length=8, nullable = false )
	private String versionNumber1;
	@Column( length=8, nullable = false )
	private String versionNumber2;
	@Column( length=8, nullable = false )
	private String versionNumber3;
	@Column( length=32, nullable = false )
	private String versionNumberTime;
	@Column( length=8, nullable = false )
	private String versionNumber4;
	@Column( length=16, nullable = false )
	private String versionAlias;
	@Column( length=256, nullable = false )
	private String url;
	@Column( length=256, nullable = false )
	private String urlWeb;
	@Column( length=256, nullable = false )
	private String urlDoc;
	@Column( length=256, nullable = false )
	private String urlTechDoc;
	@Column( nullable = false )
	private int appStatus = APPSTATUS_DISABLED;



	public Project getProject() {
		return this.project;
	}
	public void setProject( Project project ) {
		this.project = project;
	}
	public String getName() {
		return this.name;
	}
	public void setName( String name ) {
		this.name = name;
	}
	public String getAlias() {
		return this.alias;
	}
	public void setAlias( String alias ) {
		this.alias = alias;
	}
	public int getAppStatus() {
		return this.appStatus;
	}
	public void setAppStatus( int appStatus ) {
		this.appStatus = appStatus;
	}
	public String getUrl() {
		return this.url;
	}
	public void setUrl( String url ) {
		this.url = url;
	}
	public String getUrlDoc() {
		return this.urlDoc;
	}
	public void setUrlDoc( String urlDoc ) {
		this.urlDoc = urlDoc;
	}
	public String getUrlTechDoc() {
		return this.urlTechDoc;
	}
	public void setUrlTechDoc( String urlTechDoc ) {
		this.urlTechDoc = urlTechDoc;
	}
	public String getUrlWeb() {
		return this.urlWeb;
	}
	public void setUrlWeb( String urlWeb ) {
		this.urlWeb = urlWeb;
	}
	public String getVersionAlias() {
		return this.versionAlias;
	}
	public void setVersionAlias( String versionAlias ) {
		this.versionAlias = versionAlias;
	}
	public String getVersionNumber1() {
		return this.versionNumber1;
	}
	public void setVersionNumber1( String versionNumber1 ) {
		this.versionNumber1 = versionNumber1;
	}
	public String getVersionNumber2() {
		return this.versionNumber2;
	}
	public void setVersionNumber2( String versionNumber2 ) {
		this.versionNumber2 = versionNumber2;
	}
	public String getVersionNumber3() {
		return this.versionNumber3;
	}
	public void setVersionNumber3( String versionNumber3 ) {
		this.versionNumber3 = versionNumber3;
	}
	public String getVersionNumber4() {
		return this.versionNumber4;
	}
	public void setVersionNumber4( String versionNumber4 ) {
		this.versionNumber4 = versionNumber4;
	}
	public String getVersionNumberTime() {
		return this.versionNumberTime;
	}
	public void setVersionNumberTime( String versionNumberTime ) {
		this.versionNumberTime = versionNumberTime;
	}
}
